import BatchChargingIndex from './batchChargingIndex'
import BatchChargingList from './batchChargingList'


const batchCHargingRouter = {

  path: 'landlord/batchCharging',
  getChildRoutes(location, cb) {
    require.ensure([], (require) => {
      cb(null, [
        {
          path: 'list',
          getComponents(nextState, cb) {
            require.ensure([], function (require) {
              cb(null, require('./batchChargingList'))
            })
          }
        }
      ])
    })
  },

  indexRoute: {
    getComponents(location, cb) {
      require.ensure([], function (require) {
        cb(null, BatchChargingList)
      })
      return cb();
    }
  },

  getComponents(nextState, cb) {
    require.ensure([], (require) => {
      cb(null, require('./batchChargingIndex'))
    })
  }
}


export default batchCHargingRouter;

